package priv.mill.server.impl;
import java.util.List;

import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import priv.mill.dao.mapper.SysUserRoleMapper;
import priv.mill.entry.SysUserRole;
import priv.mill.server.SysUserRoleService;

@Component
public class SysUserRoleServiceImpl implements SysUserRoleService{

	private static final Logger logger = Logger
			.getLogger(SysUserRoleServiceImpl.class);

	@Autowired
	private SysUserRoleMapper sysUserRoleMapper;
	
	@Override
	public SysUserRole getSysUserRoleById(Integer sysUserRoleId) {
		return sysUserRoleMapper.getSysUserRoleById(sysUserRoleId);
	}

	@Override
	public SysUserRole getSysUserRoleByEntry(SysUserRole sysUserRole) {
		return sysUserRoleMapper.getSysUserRoleByEntry(sysUserRole);
	}

	@Override
	public List<SysUserRole> getSysUserRolesByPage(SysUserRole sysUserRole) {
		return sysUserRoleMapper.getSysUserRolesByPage(sysUserRole);
	}

	@Override
	public int updateSysUserRole(SysUserRole sysUserRole) {
		return sysUserRoleMapper.updateSysUserRole(sysUserRole);
	}

	@Override
	public int insertSysUserRole(SysUserRole sysUserRole) {
		return sysUserRoleMapper.insertSysUserRole(sysUserRole);
	}

	@Override
	public int deleteSysUserRole(Integer sysUserRoleId) {
		return sysUserRoleMapper.deleteSysUserRole(sysUserRoleId);
	}
}
